#ifndef PLUGIN_H
#define PLUGIN_H

#include <QObject>
#include <QDebug>
#include <QtPlugin>
#include "../core/EventManager/Event.h"
#include "../common/Constants.h"

class Plugin : public QObject
{
   Q_OBJECT

public:
   explicit Plugin(QObject *parent = 0);

signals:
   void signalGetConfigValue(const QString &key,
                             QVariant &value);
   void signalSetConfigValue(const QString &key,
                             QVariant &value);
   void signalPublishEvent(Event event);
   void signalSubscribeEvent(quint32 id);
   void signalUnsubscribeEvent(quint32 id);
   void signalHeartbeatResponse();

public slots:
   virtual void slotStartService() = 0;
   virtual void slotStopService() = 0;
   virtual void slotConfigUpdate(const QString &key,
                                 QVariant &value) = 0;
   virtual void slotEventNotification(Event event) = 0;
   void slotHeatbeatRequest();
};

#endif // PLUGIN_H
